Public Function GetWriteErrorMessage(ByRef objCDR As CDWriterXP, ByVal WriteError As CDWriterXPLib.eWriteError, ByVal DeviceError As CDWriterXPLib.eCDError) As String
'This function will build a string to display the error to the user
Dim strError As String
'Show the correct error message
Select Case WriteError
Case errDriveError
'If there is a drive error, you can retrieve the exact DeviceError
'Including exact Error sense data from the drive. GetLastError gives an enum
'of the error.GetErrorData returns a string representing the actual error data
'returned from the device
'Use the object browser to find the corresponding eWriteError to determine the error more thouroughly